CodeDeploy のエラー「The deployment timed out while waiting for a notification to continue」を回避するには

CodeDeploy のエラー「The deployment timed out while waiting for a notification to continue」を回避するには

Clock Icon2024.10.16

困っていた内容

CodeDeploy を利用した ECS の Blue/Green Deployment を構築しました。
デプロイを行ったところ、次のエラーでデプロイが失敗しました。

The deployment timed out while waiting for a notification to continue. This time out period is 5 minutes.

なぜでしょうか。デプロイを成功させる方法を教えてください。

どう対応すればいいの?

タイムアウト時間内に「トラフィックの再ルーティング」を実行してください。

codedeploy-the-deployment-timed-out-while-waiting-for-a-notification-to-continue 3

デプロイグループの設定で「トラフィックを再ルーティングするタイミングを指定します」を選択した場合、指定した時間内に「トラフィックの再ルーティング」を行う必要があります。指定した時間内に行わない場合、タイムアウトエラーとなります。

そのため、再ルーティングができるタイミングで、指定した時間内に「トラフィックの再ルーティング」を実行してください。

トラフィックの再ルーティングは、CodeDeploy コンソールや AWS CLI から実行できます。

また、再ルーティングができるタイミングは、デプロイグループの DeploymentReady トリガーで通知設定を行うと、Amazon SNS 経由で通知を受けることができます。

なお、デプロイ設定で「すぐにトラフィックを再ルーティング」を選択した場合は、準備が出来次第すぐに再ルーティングされるため、操作は不要です。

codedeploy-the-deployment-timed-out-while-waiting-for-a-notification-to-continue 2

また、「トラフィックの再ルーティング」は指定時間内に操作をしないとタイムアウトエラーとなりますが、「元のリビジョンの終了」のタイムアウトに関しては、エラーではなく正常終了となります。

参考資料

Problem: You see the following error message while deploying your Amazon ECS application using CodeDeploy:

The deployment timed out while waiting for a notification to continue. This time out period is n minutes.

Possible cause: This error might occur if you specified a wait time in the Specify when to reroute traffic field when you created your deployment group, but the deployment couldn't finish before the wait time expired.

この記事をシェアする

facebook logohatena logotwitter logo

© Classmethod, Inc. All rights reserved.